From: Florian Müllner Date: Wed, 9 Jul 2014 10:06:40 +0000 (+0200) Subject: viewSelector: Synthesize a new event with correct source for search X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~2344 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=a583f45cc64391fe4c7562047020c8d445010e59;p=gnome-shell.git viewSelector: Synthesize a new event with correct source for search We currently replay events that should start a search to the search entry, which is fairly dodgy. Synthesize a new event with the correct source actor instead, which is a bit less evil. --- diff --git a/js/ui/viewSelector.js b/js/ui/viewSelector.js index 918cd873a..b743fa796 100644 --- a/js/ui/viewSelector.js +++ b/js/ui/viewSelector.js @@ -508,7 +508,10 @@ const ViewSelector = new Lang.Class({ startSearch: function(event) { global.stage.set_key_focus(this._text); - this._text.event(event, true); + + let synthEvent = event.copy(); + synthEvent.set_source(this._text); + this._text.event(synthEvent, true); }, // the entry does not show the hint